<template>
    <div>
        <teleport to=".header">
            <van-nav-bar left-arrow @click-left="back">
                <template #title>
                    <router-link to="search">
                        <van-search v-model="value" shape="round" background="transparent" placeholder="请输入搜索关键词" />
                    </router-link>
                </template>
                <template #right>
                    <router-link to="/login" :style="{ color: '#fff' }">登录</router-link>
                </template>

            </van-nav-bar>
        </teleport>
    </div>
</template>

<script setup>
import { ref } from 'vue';
import { showToast } from 'vant';

const value = ref('');
const onSearch = (val) => showToast(val);
const onCancel = () => showToast('取消');
const addressBtn = () =>{

};
</script>

<style lang="scss" scoped></style>